package com.ty.util;

import java.io.Serializable;
import java.util.regex.Matcher;
import java.util.regex.Pattern;

public class StringUtil implements Serializable {

	/**
	 * serialVersionUID :
	 */
	private static final long serialVersionUID = 7147439055593664059L;

	private static Pattern linePattern = Pattern.compile("_(\\w)");

	public static String getProperty(String column) {
		Matcher matcher = linePattern.matcher(column);
		StringBuffer sb = new StringBuffer();
		while (matcher.find()) {
			matcher.appendReplacement(sb, matcher.group(1).toUpperCase());
		}
		matcher.appendTail(sb);
		return sb.toString();
	}
}
